package com.smartcommunity.entity.village;

import com.smartcommunity.bean.entity.Camera;
import com.smartcommunity.entity.ac.AccessDevice;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.List;

@Api("树模型")
@Data
public class Tree {

    @ApiModelProperty("节点id")
    private String id;
    @ApiModelProperty("节点code")
    private String code;
    @ApiModelProperty("上级节点id")
    private String parentId;
    @ApiModelProperty("节点名称")
    private String name;
    @ApiModelProperty("节点类型,dag相机设备type为1，dag门禁为2，行政区划为3，pvm设备为4,小区为5，小区分组为6")
    private Integer type;
    @ApiModelProperty("相机类型")
    private Integer deviceType;
    @ApiModelProperty("门禁信息")
    private Integer subType;
    @ApiModelProperty("经度")
    private Double lon;
    @ApiModelProperty("纬度")
    private Double lat;
    @ApiModelProperty("子节点列表")
    private List<Tree> items;

    public Tree(String id,String code,String parentId,String name,Integer type,Integer deviceType,Integer subType,Double lon,Double lat,List<Tree> items){
        this.id = id;
        this.code = code;
        this.parentId = parentId;
        this.name = name;
        this.type = type;
        this.items = items;
        this.deviceType = deviceType;
        this.subType = subType;
        this.lon = lon;
        this.lat = lat;
    }

    public Tree(String id,String code,String parentId,String name,Integer type,Integer deviceType,Integer subType,Double lon,Double lat){
        this.id = id;
        this.code = code;
        this.parentId = parentId;
        this.name = name;
        this.type = type;
        this.deviceType = deviceType;
        this.subType = subType;
        this.lon = lon;
        this.lat = lat;
    }

    public Tree(String id,String code,String parentId,String name,Integer type){
        this.id = id;
        this.code = code;
        this.parentId = parentId;
        this.name = name;
        this.type = type;
    }

}
